﻿
     /** {{ModelDescription}}  */
    export  interface I{{ModelClassName}}
    {
		{% for field in ModelFields %}
          /** {{field.ColumnDescription}}  */
        {% if field.DataType == 'nvarchar' or field.DataType == 'varchar'  or field.DataType == 'text' %}
         {{field.DbColumnName}}:string;
        {% elsif  field.DataType == 'int' and field.IsNullable == false  %}
        {{field.DbColumnName}}:number;
        {% elsif  field.DataType == 'int' and field.IsNullable == true %}
        {{field.DbColumnName}}?:number;
        {% elsif  field.DataType == 'bigint' and field.IsNullable == false  %}
         {{field.DbColumnName}}:number;
        {% elsif  field.DataType == 'bigint' and field.IsNullable == true %}
        {{field.DbColumnName}}?:number;
        {% elsif  field.DataType == 'float' and field.IsNullable == false  %}
        {{field.DbColumnName}}:number;
        {% elsif  field.DataType == 'float' and field.IsNullable == true %}
         {{field.DbColumnName}}?:number;
        {% elsif  field.DataType == 'bit' and field.IsNullable == false %}
        {{field.DbColumnName}}:boolean;
        {% elsif  field.DataType == 'bit' and field.IsNullable == true %}
        {{field.DbColumnName}}?:boolean;
        {% elsif  field.DataType == 'datetime' and field.IsNullable == false %}
        {{field.DbColumnName}}:Date;
        {% elsif  field.DataType == 'datetime' and field.IsNullable == true %}
        {{field.DbColumnName}}?:Date;
        {% elsif  field.DataType == 'date' and field.IsNullable == false %}
         {{field.DbColumnName}}:Date;
        {% elsif  field.DataType == 'date' and field.IsNullable == true %}
         {{field.DbColumnName}}?:Date;
        {% elsif  field.DataType == 'uniqueidentifier' and field.IsNullable == false %}
        {{field.DbColumnName}}:string;
        {% elsif  field.DataType == 'uniqueidentifier' and field.IsNullable == true %}
        {{field.DbColumnName}}?:string;
        {% elsif  field.DataType == 'decimal' and field.IsNullable == false %}
          {{field.DbColumnName}}:number;
        {% elsif  field.DataType == 'decimal' and field.IsNullable == true %}
         {{field.DbColumnName}}?:number;
        {% elsif  field.DataType == 'numeric' and field.IsNullable == false %}
         {{field.DbColumnName}}:number;
        {% elsif  field.DataType == 'numeric' and field.IsNullable == true %}
         {{field.DbColumnName}}?:number;
        {% else %}
        {% endif %}
		{% endfor %}
    }

